package com.yxx.business.entity;

import java.math.BigDecimal;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.yxx.common.annotation.Excel;
import com.yxx.common.core.domain.BaseColumnEntity;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.experimental.Accessors;
import lombok.*;

import javax.validation.constraints.NotNull;

/**
 * 项目信息Do对象 tb_project_info
 *
 * @author yxx
 * @date 2025-08-03
 */
@Schema(description = "项目信息Do实体")
@NoArgsConstructor
@AllArgsConstructor
@EqualsAndHashCode(callSuper = true)
@Accessors(chain = true)
@Builder
@Data
@TableName(value = "tb_project_info", autoResultMap = true)
public class TbProjectInfoDo extends BaseColumnEntity {

    private static final long serialVersionUID = 1L;

    @Schema(description = "项目ID")
    @TableId(value = "project_id", type = IdType.AUTO)
    private Long projectId;

    @Schema(description = "项目名称")
    @TableField("project_name")
    @Excel(name = "项目名称")
    private String projectName;

    @Schema(description = "项目标段")
    @TableField("project_section")
    @Excel(name = "项目标段")
    private String projectSection;

    @Schema(description = "建设单位")
    @TableField("construction_unit")
    @Excel(name = "建设单位")
    private String constructionUnit;

    @Schema(description = "设计单位")
    @TableField("design_unit")
    @Excel(name = "设计单位")
    private String designUnit;

    @Schema(description = "项目里程")
    @TableField("mileage")
    @Excel(name = "项目里程")
    private BigDecimal mileage;

    @Schema(description = "起点省份")
    @TableField("start_province")
    @Excel(name = "起点省份")
    private String startProvince;

    @Schema(description = "终点省份")
    @TableField("end_province")
    @Excel(name = "终点省份")
    private String endProvince;

    @Schema(description = "建设开始时间")
    @TableField("construction_start")
    private Date constructionStart;

    @Schema(description = "建设结束时间")
    @TableField("construction_end")
    private Date constructionEnd;

    @Schema(description = "排放因子(kgCO2e/km)")
    @TableField("transport_factor")
    private BigDecimal transportFactor;

    @Schema(description = "碳排放量(kgCO2e)")
    @TableField("total_emission")
    private BigDecimal totalEmission;

    @Schema(description = "创建者id")
    @TableField("create_by_id")
    private Long createById;

    @Schema(description = "更新者id")
    @TableField("create_by_id")
    private Long updateById;
}
